#pragma once

class CGridParam
{
public:
	CGridParam(void);
	CGridParam(	double dStartTime, double dEndTime, double paramLowBound, double paramHiBound, double paramRef);
	virtual ~CGridParam(void);

	void Assign(const CGridParam &r);
	CPoint CalcPoint(CPoint picSize, double Time, double dParam, double dDist);
	bool IsValid() const;
	bool IsIncludedTime(double dTime) const;
	bool IsIncludedRange(double dParam) const;
	double GetParamDiff(double xVal) const;

	double getXVal(int nWigth, int xPos) const;
	double getYVal(int nHeigth, int yPos) const;

	int getXPos(int nWigth, double xVal) const;
	int getYPos(int nHeigth, double yVal, double dDist) const;
protected:
	double m_dStartTime;
	double m_dEndTime;
	double m_paramLowBound;
	double m_paramHiBound;
	double m_paramRef;
};
